﻿
using System.Collections.Generic;
using System.Windows.Forms;
using GDFlacTool.Common;

namespace GDFlacTool.Forms
{
    public partial class FormPlaylist : Form
    {
        private readonly IList<Track> _tracks; 

        public FormPlaylist(IList<Track> tracks)
        {
            InitializeComponent();

            _tracks = tracks;

            txtPlaylist.Text = Functions.CreatePlaylist(_tracks);
        }

        public string GetM3uText
        {
            get { return txtPlaylist.Text; }
        }

        private void FormPlaylist_Load(object sender, System.EventArgs e)
        {
            Text = string.Format("Playlist Preview {0} Track(s)", _tracks.Count);
        }
    }
}
